import Foundation
import SwiftUI
import CalendarShared

extension WidgetColor {
    var color: ColorModel {
        switch self {
        case .red: ColorModel(light: Color(hex: "#ff2121"), dark: Color(hex: "#ff2121"))
        case .green: ColorModel(light: Color(hex: "#00bc12"), dark: Color(hex: "#00bc12"))
        case .blue: ColorModel(light: Color(hex: "#44cef6"), dark: Color(hex: "#44cef6"))
        case .brown: ColorModel(light: Color(hex: "8F5529"), dark: Color(hex: "8F5529"))
        case .orange: ColorModel(light: Color(hex: "#ff8936"), dark: Color(hex: "#ff8936"))
        case .purple: ColorModel(light: Color(hex: "#8d4bbb"), dark: Color(hex: "#8d4bbb"))
        case .white: ColorModel(light: Color(hex: "#ffffff"), dark: Color(hex: "#ffffff"))
        case .yellow: ColorModel(light: Color(hex: "#fff143"), dark: Color(hex: "#fff143"))
        case .black: ColorModel(light: Color(hex: "#161823"), dark: Color(hex: "#161823"))
        case .unknown: ColorModel(light: Color(hex: "F5F5F5"), dark: Color(hex: "20262E"))
        }
    }
}
